package com.yeyks.consumer.dal.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 消息通知表
 * </p>
 *
 * @author yun
 * @since 2019-06-25
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value="MessageNotice对象", description="消息通知表")
public class MessageNotice implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "用户id")
    @TableField("user_id")
    private Integer userId;

    @ApiModelProperty(value = "酒店id")
    @TableField("hotel_id")
    private Integer hotelId;

    @ApiModelProperty(value = "活动id")
    @TableField("activity_id")
    private Integer activityId;

    @ApiModelProperty(value = "1:订单消息通知 21、活动通知下优惠券 22、活动通知下佣金  23、活动通知下活动 24、活动通知下钱包")
    @TableField("type")
    private Integer type;

    @ApiModelProperty(value = "标题")
    @TableField("title")
    private String title;

    @ApiModelProperty(value = "消息通知内容")
    @TableField("content")
    private String content;

    @ApiModelProperty(value = "icon地址")
    @TableField("icon_url")
    private String iconUrl;

    @ApiModelProperty(value = "创建日期")
    @TableField("created_time")
    private Date createdTime;


    public static final String ID = "id";

    public static final String USER_ID = "user_id";

    public static final String HOTEL_ID = "hotel_id";

    public static final String ACTIVITY_ID = "activity_id";

    public static final String TYPE = "type";

    public static final String TITLE = "title";

    public static final String CONTENT = "content";

    public static final String ICON_URL = "icon_url";

    public static final String CREATED_TIME = "created_time";

    public enum Type {
        order(1, "订单消息通知"),
        activity_coupon(21, "活动通知下优惠券"),
        activity_commission(22, "活动通知下佣金"),
        activity_activity(23, "活动通知下活动"),
        activity_wallet(24, "活动通知下钱包"),
        order_parent_commission(31, "订单佣金上级"),
        order_two_parent_commission(32, "订单佣金上上级"),
        ACTIVITY_DOUBLE_DAN(41, "双旦红包"),
        NEW_USER_TASK(51, "新手任务");
        int value;
        String desc;

        Type(int value, String desc) {
            this.value = value;
            this. desc = desc;
        }

        public Integer value() {
            return this.value;
        }
    }

}
